package com.gang.mars.basic.generictype.demo4;

/**
 * @author gang.chen
 * @description 泛型类子类
 * @Date 2021/7/14 12:36
 */
public class AppleTest08 {
    public static void main(String[] args) {

        //1）子类为泛型类，继承父泛型类

        Apple082<String> apple082 = new Apple082<>();

        apple082.setT("gang.chen");

        String t = apple082.getT();

        System.out.println(t);


        //2）子类为非泛型类，继承自泛型类
        Apple083 apple083 = new Apple083();

        apple083.setT(100);

        System.out.println(apple083.getT());
    }
}
